<?php
require_once(dirname(__FILE__).'/include/config.inc.php');

//初始化参数检测正确性
$cid = empty($cid) ? 2 : intval($cid);
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<?php echo GetHeader(1,$cid); ?>
<link href="templates/default/style/webstyle.css" type="text/css" rel="stylesheet" />
<script type="text/javascript" src="templates/default/js/jquery.min.js"></script>
<script type="text/javascript" src="templates/default/js/top.js"></script>
</head>
<body>
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="table7 pt20">
  <tr>
    <td>
    <table width="1000" border="0" align="center" cellpadding="0" cellspacing="0" class="center mt20">
      <tr>
        <td width="238" align="center" valign="top"></td>
        <td align="center" valign="top">





<?php
	$did          = time();
	$did		  = Date($did+3600*8);
	$did          = date('YmdHis',$did) ;
	$did 		  = $did.strval(rand("1111","9999"));
	$add_time	  = time();
	$add_time	  = GetDateTime($add_time+3600*8);
?>
订单号：<?php echo $did;?>
时间：<?php echo $add_time;?><br /><br />
<table width="100%" height="39" border="0" cellpadding="0" cellspacing="0">
          <tr>
            <td height="500" valign="top">
			<form name=alipayment action="alipayjsdz/alipayapi.php" method="post" target="_blank" onsubmit="check()">

                <table width="680" height="35" border="1" align="center" cellpadding="3" cellspacing="3" class="xxx">
                  <tr>
                    <td width="64" height="35" align="center" bgcolor="eaeaea" class="zise3">序号</td>
                    <td width="282" align="center" bgcolor="eaeaea" class="zise3">配件名称</td>
                    <td width="82" align="center" bgcolor="eaeaea" class="zise3">配件价格</td>
                    <td width="88" align="center" bgcolor="eaeaea" class="zise3">数量</td>
                    <td width="104" align="center" bgcolor="eaeaea" class="zise3">金额</td>
                    </tr>
				<?php
                $i=1;
                $jine=0;
				$num=0;

				?>
                  <tr>
                    <td width="64" height="35" align="center" class="black">
					<input type="hidden" name='che_id' value="1" /><input type="hidden" name='action' value="chedel" />
					<?php echo $i;?></td>
                    <td width="282" align="center" class="black">测试测试</td>
                    <td width="82" align="center" class="black">0.1</td>
                    <td width="88" align="center" class="black">1</td>
                    <td width="104" align="center" class="black">￥0.1</td>
                    </tr>
<?php
$jine += $row1['pj_jiage']*$row1['sl'];
$num += $row1['sl'];
$che_ids[]=$row1['id'];
$i++;

?>
                </table>

<br /><p align="center">合计数量：1&nbsp;&nbsp;合计金额：￥0.1</p><br />

<div align="center">
<?php
$str="1"."#"."1"."#"."1"."#"."2"."#"."0.1"."#"."2017-5-11";
?>
<input type="hidden" name="str" value="<?php echo $str;?>"/>
<input type="hidden" name="out_trade_no" value="<?php echo 1;?>"/>
<input type="hidden" name="WIDtotal_fee" value="<?php echo '0.1';?>"/>
<br />
</div>
			<div class="clear"></div>
<input type="submit" name="submit" value="确认信息去付款" />
            </form></td>
          </tr>
        </table>
        <p>&nbsp;</p>
        <p>&nbsp;</p>
		</td>
      </tr>
    </table></td>
  </tr>
</table>

<script language="javascript">
function check(){
if(document.myform.d_name.value==""){
    alert("联系人不能为空！");
	document.myform.d_name.focus();
	return false;
}
if(document.myform.d_tel.value==""){
    alert("联系方式不能为空！");
	document.myform.d_tel.focus();
	return false;
}
if(myform.d_address.value==""){
	alert("联系地址不能为空！");
	document.myform.d_address.focus();
	return false;
}
}
</script>

</body>
</html>